package com.caochenlei.prototype.deep.mode2;

public class PersonTest {
    public static void main(String[] args) {
        //创建一个对象
        Person person = new Person("张三", 20, new IdCard("10086"));

        //克隆两个对象
        Person person1 = person.deepClone();
        Person person2 = person.deepClone();

        //打印三人信息
        System.out.println(person);
        System.out.println(person1);
        System.out.println(person2);
    }
}
